package book;

public class BookList {
    private Book[] books;
    private int OnNum;

    public Book getBook(int i) {
        return books[i];
    }

    public void setBook(int i, Book book) {
        books[i] = book;
    }

    public int getOnNum() {
        return OnNum;
    }

    public void setOnNum(int onNum) {
        OnNum = onNum;
    }

    public BookList() {
        OnNum = 3;
        books = new Book[10];
        books[0] = new Book("三国演义","罗贯中","小说",12.3);
        books[1] = new Book("红楼梦","曹雪芹","小说",12.3);
        books[2] = new Book("水浒传","施耐庵","小说",12.3);

    }
}
